package com.zc.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.zc.dto.ClassExamStatsDTO;
import com.zc.pojo.Scores;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

/**
 * @author zc
 * @Date 2025/8/22
 * @apiNote
 */
public interface ExamStatisticsService extends IService<Scores> {

    List<ClassExamStatsDTO> getClassStatsForExam(Integer examId,
                                                 Integer specifiedScore,
                                                 Integer excellentScore,
                                                 Integer passScore);
    void calculateAdvancedStats(List<Map<String, Object>> studentScores,
                                Map<String, ClassExamStatsDTO> classStatsMap,
                                int specifiedScore,
                                int excellentScore,
                                int passScore);
    void calculatePointsAndSegments(ClassExamStatsDTO classDTO, double numericScore);
    BigDecimal calculateRate(int count, int total);
    BigDecimal convertToBigDecimal(Object value);

}
